﻿using System;
using System.Collections.Generic;
using System.Text;

namespace Technoera.Common.QueryModel
{
    [Serializable()]
    public class SortParameter
    {
        public SortParameter(string sortExpression, SortDirection sortDirection)
        {
            this.SortExpression = sortExpression;
            this.SortDirection = sortDirection;
        }

        private string _sortExpression;
        public virtual string SortExpression
        {
            get
            {
                if (_sortExpression == null)
                    _sortExpression = string.Empty;

                return _sortExpression;
            }
            set
            {
                _sortExpression = value;
            }
        }

        public SortDirection SortDirection { get; set; }
    }
}
